<%@ page import="java.util.List" %>
<%@ page import="ar.drools.apuestas.modelo.*" %>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="">

<title>Apuestas Online</title>

<!-- Bootstrap core CSS -->
<link href="dist/css/bootstrap.css" rel="stylesheet">

<!-- Custom styles for this template -->
<link href="dist/css/jumbotron.css" rel="stylesheet">

<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
      <script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
    <![endif]-->
</head>

<body>

	<div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
		<div class="container">
			<div class="navbar-header">
				<button type="button" class="navbar-toggle" data-toggle="collapse"
					data-target=".navbar-collapse">
					<span class="sr-only">Toggle navigation</span> <span
						class="icon-bar"></span> <span class="icon-bar"></span> <span
						class="icon-bar"></span>
				</button>
				<a class="navbar-brand" href="Home">Apuestas Online</a>
			</div>
		</div>
	</div>

	<!-- Main jumbotron for a primary marketing message or call to action -->
	<div class="jumbotron">
		<div class="container">
			<h1>Resultados</h1>
			<a class="btn btn-primary btn-lg" href="Home" role="button">Volver</a>
		</div>
	</div>

	<div class="container">
		<!-- Example row of columns -->
		<div class="row">
			<table class="table table-striped table-condensed">
				<thead>
					<tr>
						<th>Piloto</th>
						<th>Categoria</th>
						<th>Apuesta</th>
					</tr>
				</thead>
				<tbody>
					<% 
					List<Piloto> listaPilotos = (List<Piloto>) request.getAttribute("PILOTOS");
					for(Piloto piloto : listaPilotos){ %>
						<tr>
							<td><%=piloto.getNombre()%></td>
							<td><%=piloto.getResultado()%></td>
							<td><%=piloto.calcularApuesta()%></td>
						</tr>
					<% } %>
				</tbody>
			</table>
		</div>
	</div>

	<!-- Bootstrap core JavaScript
    ================================================== -->
	<!-- Placed at the end of the document so the pages load faster -->
	<script src="https://code.jquery.com/jquery-1.10.2.min.js"></script>
	<script src="dist/js/bootstrap.min.js"></script>
</body>
</html>
